﻿
'use strict'; 
var eventsApp = angular.module('eventsApp', ['ngResource','ngRoute'])
.config(function ($routeProvider) {
    $routeProvider.when('/event',
        {
            templateUrl:'/eventreg/app/template/events.html',
            controller: 'eventCtrl'
        }),
    
    $routeProvider.when('/newEvent',
        {
            templateUrl: '/eventreg/app/template/newevent.html',
            controller: 'eventCtrl'
        })

    $routeProvider.when('/newEvent/:duration',
       {
           templateUrl: '/eventreg/app/template/newevent.html',
           controller: 'sessionCtrl'
       })
    $routeProvider.otherwise({redirectTo:'/event'});
});
